80212: Function test xfi:duplicate-tuple

Documentation

Tests of function xfi:duplicate-tuple($left as schema-element(xbrli:tuple), $right as schema-element(xbrli:tuple)) as xs:boolean UsesExample 25 of XBRL Spec v2.1.

Owners

Name Affiliation Email Start End
Herm Fischer UBMatrix / Mark V Systems fischer@markv.com 19-02-2008 at 00:00:00

References

http://www.xbrl.org/Specification/XF-PWD-2006-12-07.htm#_Toc152670713

Test Case Variations


V-01 Item, not an tuple

Documentation

XPath-defined error for node type incorrect.

Inputs

  • schema: example25.xsd
  • instance: example25-instance.xml (DTS Discovery starting point) (ID=V01)
  • Function Call: xfi:duplicate-tuple( //s:name[@id eq 'fName'], //s:name[@id eq 'gName'] )

    (against file V01)

Outputs

  • Error code: xqt-err:XPTY0004

V-02 Item, not an tuple

Documentation

XPath-defined error for node type incorrect.

Inputs

  • schema: example25.xsd
  • instance: example25-instance.xml (DTS Discovery starting point) (ID=V02)
  • Function Call: xfi:duplicate-tuple( //s:name[@id eq 'bName'], //s:name[@id eq 'cName'] )

    (against file V02)

Outputs

  • Error code: xqt-err:XPTY0004

V-03 Item, not an tuple

Documentation

XPath-defined error for node type incorrect.

Inputs

  • schema: example25.xsd
  • instance: example25-instance.xml (DTS Discovery starting point) (ID=V03)
  • Function Call: xfi:duplicate-tuple( //s:gross[@id eq 'bGross'], //s:gross[@id eq 'cGross'] )

    (against file V03)

Outputs

  • Error code: xqt-err:XPTY0004

V-04 Duplicates because p-equal, and child items name, gross, returns and net are all v-equal

Documentation

Inputs

  • schema: example25.xsd
  • instance: example25-instance.xml (DTS Discovery starting point) (ID=V04)
  • Function Call: xfi:duplicate-tuple( //s:customer[@id eq 'bCustomer'], //s:customer[@id eq 'cCustomer'] )

    (against file V04)

Outputs

  • Result test: $result eq true()

V-05 Item, not an tuple

Documentation

XPath-defined error for node type incorrect.

Inputs

  • schema: example25.xsd
  • instance: example25-instance.xml (DTS Discovery starting point) (ID=V05)
  • Function Call: xfi:duplicate-tuple( //s:returns[@id eq 'bReturns'], //s:returns[@id eq 'dReturns'] )

    (against file V05)

Outputs

  • Error code: xqt-err:XPTY0004

V-06 Not duplicates because p-equal, and child items b name and b gross are v-equal to d name and d gross, and child items b returns and b net are not v-equal to b returns and b net

Documentation

Inputs

  • schema: example25.xsd
  • instance: example25-instance.xml (DTS Discovery starting point) (ID=V06)
  • Function Call: xfi:duplicate-tuple( //s:customer[@id eq 'bCustomer'], //s:customer[@id eq 'dCustomer'] )

    (against file V06)

Outputs

  • Result test: $result eq false()

V-07 Item, not an tuple

Documentation

XPath-defined error for node type incorrect.

Inputs

  • schema: example25.xsd
  • instance: example25-instance.xml (DTS Discovery starting point) (ID=V07)
  • Function Call: xfi:duplicate-tuple( //s:gross[@id eq 'lGross'], //s:gross[@id eq 'mGross'] )

    (against file V07)

Outputs

  • Error code: xqt-err:XPTY0004

Revisions

Name On Details
Herm Fischer 19-02-2008 at 00:00:00 Created the test case.